namespace Demo.Model.Migrations
{
    using Demo.Model.Tables;
    using System;
    using System.Data.Entity;
    using System.Data.Entity.Migrations;
    using System.Linq;

    internal sealed class Configuration : DbMigrationsConfiguration<Demo.Model.DatabaseContext.ProductContext>
    {
        public Configuration()
        {
            AutomaticMigrationsEnabled = false;
        }

        protected override void Seed(Demo.Model.DatabaseContext.ProductContext context)
        {
            
            //  This method will be called after migrating to the latest version.

            //  You can use the DbSet<T>.AddOrUpdate() helper extension method 
            //  to avoid creating duplicate seed data. E.g.
            //

            //var Items = Enumerable.Range(1, 200).Select(x => new Products() {             
            //Price=x*100,
            //Quantity=x,
            //Name="Product"+x,
            //Description="Product Description"+x
            //}).ToArray();

            //context.Product.AddOrUpdate<Products>(x => new { x.ID }, Items);
           // context.SaveChanges();
        }
    }
}
